FIND_PATH(PHYSFS_INCLUDE_DIR physfs.h)
FIND_LIBRARY(PHYSFS_LIBRARY NAMES physfs physfs-static)

IF(PHYSFS_INCLUDE_DIR AND PHYSFS_LIBRARY)
    SET(EXTERNAL_INCLUDE_DIR ${PHYSFS_INCLUDE_DIR})
    SET(EXTERNAL_LIBRARIES ${PHYSFS_LIBRARY})
    
    SET(LIBRARY_NAME osgdb_physfs)
    SET(LIBRARY_FILES ReaderWriterPhysFS.cpp)
    START_LIBRARY()
ENDIF(PHYSFS_INCLUDE_DIR AND PHYSFS_LIBRARY)
